home *** CD-ROM | disk | FTP | other *** search
- SYNTAX
- cut -clist [filename ...]
- cut -flist [-dc] [filename ...]
-
- DESCRIPTION
- Use cut to cut out columns from a table or fields from each
- line of a file; in data base parlance, it implements the
- projection of a relation. The fields as specified by list
- can be of fixed length, (such as on a punched card), or of
- variable length between lines. They can be marked with a
- field delimiter character, such as TAB (as specified with
- the -d option). cut can be used as a filter; if no files
- are given, the standard input is used. In addition, a file
- name of `-' explicitly refers to the standard input.
-
- OPTIONS
- -clist
- By character position. list is a comma-separated list
- of integer field numbers (in increasing order), with an
- optional `-' to indicate ranges:
-
- 1,4,7
- characters 1, 4 and 7
- 1-3,8
- characters 1 through 3, and 8
-
- -flist
- By field position. Instead of character positions,
- list specifies fields that are separated a delimiter
- (normally a TAB):
-
- 1,4,7
- fields 1, 4 and 7
-
- Lines with no field delimiters are normally passed
- through intact (to allow for subheadings).
-
- -dc Set the field delimiter to c. The default is a TAB.
- Characters with special meaning to the shell such as a
- TAB or SPACE characters, must be quoted.
-
- AUTHOR
- Adolfo Villafiorita (adolfo@frege.mrg.dist.unige.it)
-